﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class apps_ahmidea_pages_AHMIDEAF02 : System.Web.UI.Page
{
    string vappid = "AHMIDEA";
    string vformid = "AHMIDEA_AHMIDEAF02";

    protected void Page_Load(object sender, EventArgs e)
    {
        AHMIDEAIdentity id = (AHMIDEAIdentity)HttpContext.Current.User.Identity;
        formHeader.InnerHtml = AHMIDEAFunctions.GetFormHeader(vappid, vformid);

        using (DC_AHMIDEADataContext dc = new DC_AHMIDEADataContext())
        {
            var u = dc.AHMIDEA_MSTPROFILEs.FirstOrDefault(i=>i.vuserid==AHMIDEAFunctions.ContextUser(HttpContext.Current));
            if (u != null) {
                txtUsername.Attributes.Add("value", id.Name);
                txtDispName.Attributes.Add("value", u.vdisplayname);
                txtEmail.Attributes.Add("value", u.vemail);
            }
        }

    }
}